<!DOCTYPE html>

<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
<head>
  <meta charset="utf-8" />
  <title>Create a Math Function Raster dataset</title>
  <style>
    table, th, td {
      border: 1px solid black;
      border-collapse: collapse;
    }
    th, td {
      padding: 5px;
    }
    th {
      font-weight: bold;
    }
  </style>
</head>
<body>
  ## Create a Math Function Raster dataset

This topic shows how to create a Math Function Raster dataset combining multiple operations together into a complex equation. It opens the raster datasets, applies two Math Function Raster operations (adding two rasters together, then dividing by a third raster) and saves the created Function Raster dataset to the specified file.  

```
Language:              C#, VB
Subject:               Spatial Analyst
Organization:          Esri, http://www.esri.com
Date:                  10/17/2019
ArcObjects SDK:        10.8
Visual Studio:         2017, 2019
.NET Target Framework: 4.5
```

### Resources

* [ArcObjects .NET API Reference online](http://desktop.arcgis.com/en/arcobjects/latest/net/webframe.htm)  
* [Sample Data Download](../../releases)  
* [What's new](http://desktop.arcgis.com/en/arcobjects/latest/net/webframe.htm#91cabc68-2271-400a-8ff9-c7fb25108546.htm)  
* [Download the ArcObjects SDK for .Net from MyEsri.com](https://my.esri.com/)  

### Usage
1. Start Visual Studio and open the solution file.  
1. Edit the strings in the "Specify input directory and dataset name" region to specify the directory and name of the input dataset, and the full path to the output dataset including the .afr extension.  
1. Compile and run the program.  
1. If the program succeeds, the console shows a "Success" message. If an error occurs, it shows on the console window.  
1. Load the created output .afr file into ArcMap or ArcCatalog, which reflects the processing results.  

#### See Also  
[Sample: Create a Function Raster dataset](../../../Net/Raster/CreateFunctionRasterDataset)  

---------------------------------

#### Licensing  
<table><tr><th> Development licensing </th><th> Deployment licensing </th></tr>
<tr><td> ArcGIS Desktop Advanced: Spatial Analyst </td><td> ArcGIS Desktop Advanced: Spatial Analyst </td></tr>  
<tr><td> ArcGIS Desktop Standard: Spatial Analyst </td><td> ArcGIS Desktop Standard: Spatial Analyst </td></tr>  
<tr><td> ArcGIS Desktop Basic: Spatial Analyst </td><td> ArcGIS Desktop Basic: Spatial Analyst </td></tr>  
</table>
</body>
</html>